using Sustainalytics.ESGRatings.Computing.Entities;
using System;
using System.Collections.Generic;

namespace Sustainalytics.ESGRatings.BusinessLogic.Computing
{
    public class ESGComputeResult : IDisposable
    {
        RatingsResult _ratings;
        IndicatorsConfiguration _configuration;

        Guid[] _companiesMap;
        int[] _companiesHeadsGroups;

        //Null if CompaniesNo = 0
        public RatingsResult Ratings
        {
            get { return _ratings; }
            set { _ratings = value; }
        }
        public bool IsDefaultWeightMatrix { get; set; }

        public Guid SetId { get; set; }
        public IndicatorsConfiguration Configuration
        {
            get { return _configuration; }
            set { _configuration = value; }
        }

        public Guid[] CompaniesMap
        {
            get { return _companiesMap; }
            set { _companiesMap = value; }
        }

        public Dictionary<Guid, string> CompaniesNames { get; set; }

        public int[] CompaniesHeadsGroups
        {
            get { return _companiesHeadsGroups; }
            set { _companiesHeadsGroups = value; }
        }

        public ESGRatingsOptions.IncludeFlags ComputeOptions { get; set; }

        public WeightMatrixStruct MatrixInfo { get; set; }

        public Dictionary<Guid, IndicatorDataStruct[]> IndicatorsScores { get; set; }

        public void Dispose()
        {
            if (_ratings != null)
            {
                _ratings.Dispose();

            }

        }


    }
}
